package com.sskj.gocoin.p.activity;

import com.lzy.okgo.OkGo;
import com.lzy.okgo.model.Response;
import com.sskj.gocoin.m.HttpConfig;
import com.sskj.gocoin.m.bean.HttpData;
import com.sskj.gocoin.m.bean.VerifyReasonBean;
import com.sskj.gocoin.m.http.JsonCallBack;
import com.sskj.gocoin.p.base.BasePresenter;
import com.sskj.gocoin.v.activity.VerifyResultActivity;

public class VerifyResultActivityPresenter extends BasePresenter<VerifyResultActivity> {
    public void submitVerifyEnd(String img1, String img2, String img3) {
        OkGo.<HttpData<VerifyReasonBean>>post(HttpConfig.BASE_URL + HttpConfig.HIGH_VERIFY_RESULT)
                .execute(new JsonCallBack<HttpData<VerifyReasonBean>>(this) {
                    @Override
                    public void _onSuccess(Response<HttpData<VerifyReasonBean>> response) {
                        HttpData<VerifyReasonBean> body = response.body();
                        if (body.getCode() == 200) {
                            mView.updateUi(body.getData().getReason());
                        }
                    }
                });
    }
}
